﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using XCode;
using XCode.DataAccessLayer;

namespace BingZi.HY.Core.Entities.Center
{
	/// <summary>
	/// 公司信息
	/// </summary>
	[Serializable]
	[DataObject]
	[Description("公司信息")]
	[BindTable("app_Company", Description = "公司信息", ConnName = "Center", DbType = DatabaseType.SqlServer)]
	public partial class app_Company
	{
		#region 属性
		private Int32 _ValueID;
		/// <summary>
		/// 公司编号
		/// </summary>
        [Description("公司编号")]
		[DataObjectField(true, true, false, 10)]
        [BindColumn(1, "ValueID", "公司编号", "", "int", 10, 0, false)]
		public Int32 ValueID
		{
			get { return _ValueID; }
			set { if (OnPropertyChange("ValueID", value)) _ValueID = value; }
		}

		private Int32 _UserID;
		/// <summary>
		/// 用户
		/// </summary>
		[Description("用户")]
		[DataObjectField(false, false, false, 10)]
		[BindColumn(2, "UserID", "用户", "", "int", 10, 0, false)]
		public Int32 UserID
		{
			get { return _UserID; }
			set { if (OnPropertyChange("UserID", value)) _UserID = value; }
		}

		private String _UserName;
		/// <summary>
		/// 用户名
		/// </summary>
		[Description("用户名")]
		[DataObjectField(false, false, false, 50)]
		[BindColumn(3, "UserName", "用户名", "", "nvarchar(50)", 0, 0, true)]
		public String UserName
		{
			get { return _UserName; }
			set { if (OnPropertyChange("UserName", value)) _UserName = value; }
		}

		private String _c_Name;
		/// <summary>
		/// 公司名称
		/// </summary>
		[Description("公司名称")]
		[DataObjectField(false, false, false, 100)]
		[BindColumn(4, "c_Name", "公司名称", "", "nvarchar(100)", 0, 0, true)]
		public String c_Name
		{
			get { return _c_Name; }
			set { if (OnPropertyChange("c_Name", value)) _c_Name = value; }
		}

		private Int32 _c_Area;
		/// <summary>
		/// 所属区域
		/// </summary>
		[Description("所属区域")]
		[DataObjectField(false, false, false, 10)]
		[BindColumn(5, "c_Area", "所属区域", "", "int", 10, 0, false)]
		public Int32 c_Area
		{
			get { return _c_Area; }
			set { if (OnPropertyChange("c_Area", value)) _c_Area = value; }
		}

        private Int32 _c_Type;
		/// <summary>
		/// 公司类型
		/// </summary>
		[Description("公司类型")]
		[DataObjectField(false, false, false, 3)]
		[BindColumn(6, "c_Type", "公司类型", "", "tinyint", 3, 0, false)]
		public Int32 c_Type
		{
			get { return _c_Type; }
			set { if (OnPropertyChange("c_Type", value)) _c_Type = value; }
		}

		private Int32 _c_Category;
		/// <summary>
		/// 所属分类
		/// </summary>
		[Description("所属分类")]
		[DataObjectField(false, false, false, 10)]
		[BindColumn(7, "c_Category", "所属分类", "", "int", 10, 0, false)]
		public Int32 c_Category
		{
			get { return _c_Category; }
			set { if (OnPropertyChange("c_Category", value)) _c_Category = value; }
		}

		private String _c_Brand;
		/// <summary>
		/// 主营品牌
		/// </summary>
		[Description("主营品牌")]
		[DataObjectField(false, false, true, 100)]
		[BindColumn(8, "c_Brand", "主营品牌", "", "nvarchar(100)", 0, 0, true)]
		public String c_Brand
		{
			get { return _c_Brand; }
			set { if (OnPropertyChange("c_Brand", value)) _c_Brand = value; }
		}

		private String _c_MainProducts;
		/// <summary>
		/// 主营产品
		/// </summary>
		[Description("主营产品")]
		[DataObjectField(false, false, true, 200)]
		[BindColumn(9, "c_MainProducts", "主营产品", "", "nvarchar(200)", 0, 0, true)]
		public String c_MainProducts
		{
			get { return _c_MainProducts; }
			set { if (OnPropertyChange("c_MainProducts", value)) _c_MainProducts = value; }
		}

		private String _c_BusinessLicence;
		/// <summary>
		/// 营业执照编号
		/// </summary>
		[Description("营业执照编号")]
		[DataObjectField(false, false, true, 50)]
		[BindColumn(10, "c_BusinessLicence", "营业执照编号", "", "nvarchar(50)", 0, 0, true)]
		public String c_BusinessLicence
		{
			get { return _c_BusinessLicence; }
			set { if (OnPropertyChange("c_BusinessLicence", value)) _c_BusinessLicence = value; }
		}

		private String _c_BusinessLicenceSrc;
		/// <summary>
		/// 营业执照
		/// </summary>
		[Description("营业执照")]
		[DataObjectField(false, false, true, 150)]
		[BindColumn(11, "c_BusinessLicenceSrc", "营业执照", "", "varchar(150)", 0, 0, false)]
		public String c_BusinessLicenceSrc
		{
			get { return _c_BusinessLicenceSrc; }
			set { if (OnPropertyChange("c_BusinessLicenceSrc", value)) _c_BusinessLicenceSrc = value; }
		}

		private String _c_Address;
		/// <summary>
		/// 办公地址
		/// </summary>
		[Description("办公地址")]
		[DataObjectField(false, false, true, 200)]
		[BindColumn(12, "c_Address", "办公地址", "", "nvarchar(200)", 0, 0, true)]
		public String c_Address
		{
			get { return _c_Address; }
			set { if (OnPropertyChange("c_Address", value)) _c_Address = value; }
		}

		private String _c_Logo;
		/// <summary>
		/// 公司标志
		/// </summary>
		[Description("公司标志")]
		[DataObjectField(false, false, true, 150)]
		[BindColumn(13, "c_Logo", "公司标志", "", "varchar(150)", 0, 0, false)]
		public String c_Logo
		{
			get { return _c_Logo; }
			set { if (OnPropertyChange("c_Logo", value)) _c_Logo = value; }
		}

		private String _c_Photo;
		/// <summary>
		/// 公司相片
		/// </summary>
		[Description("公司相片")]
		[DataObjectField(false, false, true, 150)]
		[BindColumn(14, "c_Photo", "公司相片", "", "varchar(150)", 0, 0, false)]
		public String c_Photo
		{
			get { return _c_Photo; }
			set { if (OnPropertyChange("c_Photo", value)) _c_Photo = value; }
		}

		private String _c_Introduce;
		/// <summary>
		/// 公司介绍
		/// </summary>
		[Description("公司介绍")]
		[DataObjectField(false, false, true, 512)]
		[BindColumn(15, "c_Introduce", "公司介绍", "", "nvarchar(512)", 0, 0, true)]
		public String c_Introduce
		{
			get { return _c_Introduce; }
			set { if (OnPropertyChange("c_Introduce", value)) _c_Introduce = value; }
		}

		private String _c_HomePage;
		/// <summary>
		/// 公司主页
		/// </summary>
		[Description("公司主页")]
		[DataObjectField(false, false, true, 150)]
		[BindColumn(16, "c_HomePage", "公司主页", "", "varchar(150)", 0, 0, false)]
		public String c_HomePage
		{
			get { return _c_HomePage; }
			set { if (OnPropertyChange("c_HomePage", value)) _c_HomePage = value; }
		}

		private String _c_SeoKeyWord;
		/// <summary>
		/// SEO关键字
		/// </summary>
		[Description("SEO关键字")]
		[DataObjectField(false, false, true, 100)]
		[BindColumn(17, "c_SeoKeyWord", "SEO关键字", "", "nvarchar(100)", 0, 0, true)]
		public String c_SeoKeyWord
		{
			get { return _c_SeoKeyWord; }
			set { if (OnPropertyChange("c_SeoKeyWord", value)) _c_SeoKeyWord = value; }
		}

		private String _c_SeoDescription;
		/// <summary>
		/// SEO描述
		/// </summary>
		[Description("SEO描述")]
		[DataObjectField(false, false, true, 200)]
		[BindColumn(18, "c_SeoDescription", "SEO描述", "", "nvarchar(200)", 0, 0, true)]
		public String c_SeoDescription
		{
			get { return _c_SeoDescription; }
			set { if (OnPropertyChange("c_SeoDescription", value)) _c_SeoDescription = value; }
		}

		private Int32 _c_LastUserID;
		/// <summary>
        /// 最后操作用户
		/// </summary>
		[Description("最后操作用户")]
		[DataObjectField(false, false, false, 10)]
		[BindColumn(19, "c_LastUserID", "", "0", "int", 10, 0, false)]
		public Int32 c_LastUserID
		{
			get { return _c_LastUserID; }
			set { if (OnPropertyChange("c_LastUserID", value)) _c_LastUserID = value; }
		}

		private DateTime _c_LastTime;
		/// <summary>
		/// 最后操作时间
		/// </summary>
        [Description("最后操作时间")]
		[DataObjectField(false, false, false, 3)]
        [BindColumn(20, "c_LastTime", "最后操作时间", "", "datetime", 3, 0, false)]
		public DateTime c_LastTime
		{
			get { return _c_LastTime; }
			set { if (OnPropertyChange("c_LastTime", value)) _c_LastTime = value; }
		}

		private String _c_LastIP;
		/// <summary>
		/// 最后操作IP
		/// </summary>
        [Description("最后操作IP")]
		[DataObjectField(false, false, false, 15)]
        [BindColumn(21, "c_LastIP", "最后操作IP", "", "varchar(15)", 0, 0, false)]
		public String c_LastIP
		{
			get { return _c_LastIP; }
			set { if (OnPropertyChange("c_LastIP", value)) _c_LastIP = value; }
		}

		private Int32 _c_State;
		/// <summary>
		/// 状态(0:待审核,1:已审核,2:已锁定)
		/// </summary>
		[Description("状态(0:待审核,1:已审核,2:已锁定)")]
		[DataObjectField(false, false, false, 3)]
		[BindColumn(22, "c_State", "状态(0:待审核,1:已审核,2:已锁定)", "0", "tinyint", 3, 0, false)]
        public Int32 c_State
		{
			get { return _c_State; }
			set { if (OnPropertyChange("c_State", value)) _c_State = value; }
		}

		private String _U_Email;
		/// <summary>
		/// 邮箱
		/// </summary>
        [Description("邮箱")]
		[DataObjectField(false, false, false, 50)]
		[BindColumn(23, "U_Email", "", "", "varchar(50)", 0, 0, false)]
		public String U_Email
		{
			get { return _U_Email; }
			set { if (OnPropertyChange("U_Email", value)) _U_Email = value; }
		}

		private String _U_MSN;
		/// <summary>
		/// MSN
		/// </summary>
		[Description("MSN")]
		[DataObjectField(false, false, true, 50)]
		[BindColumn(24, "U_MSN", "MSN", "", "varchar(50)", 0, 0, false)]
		public String U_MSN
		{
			get { return _U_MSN; }
			set { if (OnPropertyChange("U_MSN", value)) _U_MSN = value; }
		}

		private Int32 _U_QQ;
		/// <summary>
		/// QQ
		/// </summary>
		[Description("QQ")]
		[DataObjectField(false, false, true, 10)]
		[BindColumn(25, "U_QQ", "QQ", "", "int", 10, 0, false)]
		public Int32 U_QQ
		{
			get { return _U_QQ; }
			set { if (OnPropertyChange("U_QQ", value)) _U_QQ = value; }
		}

		private String _U_MobilePhone;
		/// <summary>
		/// 移动电话
		/// </summary>
		[Description("移动电话")]
		[DataObjectField(false, false, true, 20)]
		[BindColumn(26, "U_MobilePhone", "移动电话", "", "varchar(20)", 0, 0, false)]
		public String U_MobilePhone
		{
			get { return _U_MobilePhone; }
			set { if (OnPropertyChange("U_MobilePhone", value)) _U_MobilePhone = value; }
		}

		private String _U_Phone;
		/// <summary>
		/// 电话
		/// </summary>
		[Description("电话")]
		[DataObjectField(false, false, true, 20)]
		[BindColumn(27, "U_Phone", "电话", "", "varchar(20)", 0, 0, false)]
		public String U_Phone
		{
			get { return _U_Phone; }
			set { if (OnPropertyChange("U_Phone", value)) _U_Phone = value; }
		}

		private String _U_Fax;
		/// <summary>
		/// 传真
		/// </summary>
		[Description("传真")]
		[DataObjectField(false, false, true, 20)]
		[BindColumn(28, "U_Fax", "传真", "", "varchar(20)", 0, 0, false)]
		public String U_Fax
		{
			get { return _U_Fax; }
			set { if (OnPropertyChange("U_Fax", value)) _U_Fax = value; }
		}

		private String _U_Position;
		/// <summary>
		/// 职位
		/// </summary>
		[Description("职位")]
		[DataObjectField(false, false, true, 20)]
		[BindColumn(29, "U_Position", "职位", "", "varchar(20)", 0, 0, false)]
		public String U_Position
		{
			get { return _U_Position; }
			set { if (OnPropertyChange("U_Position", value)) _U_Position = value; }
		}
		#endregion

		#region 获取/设置 字段值
		/// <summary>
		/// 获取/设置 字段值。
		/// 一个索引，基类使用反射实现。
		/// 派生实体类可重写该索引，以避免反射带来的性能损耗
		/// </summary>
		/// <param name="name">字段名</param>
		/// <returns></returns>
		public override Object this[String name]
		{
			get
			{
				switch (name)
				{
					case "ValueID" : return _ValueID;
					case "UserID" : return _UserID;
					case "UserName" : return _UserName;
					case "c_Name" : return _c_Name;
					case "c_Area" : return _c_Area;
					case "c_Type" : return _c_Type;
					case "c_Category" : return _c_Category;
					case "c_Brand" : return _c_Brand;
					case "c_MainProducts" : return _c_MainProducts;
					case "c_BusinessLicence" : return _c_BusinessLicence;
					case "c_BusinessLicenceSrc" : return _c_BusinessLicenceSrc;
					case "c_Address" : return _c_Address;
					case "c_Logo" : return _c_Logo;
					case "c_Photo" : return _c_Photo;
					case "c_Introduce" : return _c_Introduce;
					case "c_HomePage" : return _c_HomePage;
					case "c_SeoKeyWord" : return _c_SeoKeyWord;
					case "c_SeoDescription" : return _c_SeoDescription;
					case "c_LastUserID" : return _c_LastUserID;
					case "c_LastTime" : return _c_LastTime;
					case "c_LastIP" : return _c_LastIP;
					case "c_State" : return _c_State;
					case "U_Email" : return _U_Email;
					case "U_MSN" : return _U_MSN;
					case "U_QQ" : return _U_QQ;
					case "U_MobilePhone" : return _U_MobilePhone;
					case "U_Phone" : return _U_Phone;
					case "U_Fax" : return _U_Fax;
					case "U_Position" : return _U_Position;
					default: return base[name];
				}
			}
			set
			{
				switch (name)
				{
					case "ValueID" : _ValueID = Convert.ToInt32(value); break;
					case "UserID" : _UserID = Convert.ToInt32(value); break;
					case "UserName" : _UserName = Convert.ToString(value); break;
					case "c_Name" : _c_Name = Convert.ToString(value); break;
					case "c_Area" : _c_Area = Convert.ToInt32(value); break;
					case "c_Type" : _c_Type = Convert.ToInt32(value); break;
					case "c_Category" : _c_Category = Convert.ToInt32(value); break;
					case "c_Brand" : _c_Brand = Convert.ToString(value); break;
					case "c_MainProducts" : _c_MainProducts = Convert.ToString(value); break;
					case "c_BusinessLicence" : _c_BusinessLicence = Convert.ToString(value); break;
					case "c_BusinessLicenceSrc" : _c_BusinessLicenceSrc = Convert.ToString(value); break;
					case "c_Address" : _c_Address = Convert.ToString(value); break;
					case "c_Logo" : _c_Logo = Convert.ToString(value); break;
					case "c_Photo" : _c_Photo = Convert.ToString(value); break;
					case "c_Introduce" : _c_Introduce = Convert.ToString(value); break;
					case "c_HomePage" : _c_HomePage = Convert.ToString(value); break;
					case "c_SeoKeyWord" : _c_SeoKeyWord = Convert.ToString(value); break;
					case "c_SeoDescription" : _c_SeoDescription = Convert.ToString(value); break;
					case "c_LastUserID" : _c_LastUserID = Convert.ToInt32(value); break;
					case "c_LastTime" : _c_LastTime = Convert.ToDateTime(value); break;
					case "c_LastIP" : _c_LastIP = Convert.ToString(value); break;
					case "c_State" : _c_State = Convert.ToInt32(value); break;
					case "U_Email" : _U_Email = Convert.ToString(value); break;
					case "U_MSN" : _U_MSN = Convert.ToString(value); break;
					case "U_QQ" : _U_QQ = Convert.ToInt32(value); break;
					case "U_MobilePhone" : _U_MobilePhone = Convert.ToString(value); break;
					case "U_Phone" : _U_Phone = Convert.ToString(value); break;
					case "U_Fax" : _U_Fax = Convert.ToString(value); break;
					case "U_Position" : _U_Position = Convert.ToString(value); break;
					default: base[name] = value; break;
				}
			}
		}
		#endregion

		#region 字段名
		/// <summary>
		/// 取得公司信息字段名的快捷方式
		/// </summary>
		public class _
		{
			///<summary>
			/// 
			///</summary>
			public const String ValueID = "ValueID";

			///<summary>
			/// 用户
			///</summary>
			public const String UserID = "UserID";

			///<summary>
			/// 用户名
			///</summary>
			public const String UserName = "UserName";

			///<summary>
			/// 公司名称
			///</summary>
			public const String c_Name = "c_Name";

			///<summary>
			/// 所属区域
			///</summary>
			public const String c_Area = "c_Area";

			///<summary>
			/// 公司类型
			///</summary>
			public const String c_Type = "c_Type";

			///<summary>
			/// 所属分类
			///</summary>
			public const String c_Category = "c_Category";

			///<summary>
			/// 主营品牌
			///</summary>
			public const String c_Brand = "c_Brand";

			///<summary>
			/// 主营产品
			///</summary>
			public const String c_MainProducts = "c_MainProducts";

			///<summary>
			/// 营业执照编号
			///</summary>
			public const String c_BusinessLicence = "c_BusinessLicence";

			///<summary>
			/// 营业执照
			///</summary>
			public const String c_BusinessLicenceSrc = "c_BusinessLicenceSrc";

			///<summary>
			/// 办公地址
			///</summary>
			public const String c_Address = "c_Address";

			///<summary>
			/// 公司标志
			///</summary>
			public const String c_Logo = "c_Logo";

			///<summary>
			/// 公司相片
			///</summary>
			public const String c_Photo = "c_Photo";

			///<summary>
			/// 公司介绍
			///</summary>
			public const String c_Introduce = "c_Introduce";

			///<summary>
			/// 公司主页
			///</summary>
			public const String c_HomePage = "c_HomePage";

			///<summary>
			/// SEO关键字
			///</summary>
			public const String c_SeoKeyWord = "c_SeoKeyWord";

			///<summary>
			/// SEO描述
			///</summary>
			public const String c_SeoDescription = "c_SeoDescription";

			///<summary>
			/// 
			///</summary>
			public const String c_LastUserID = "c_LastUserID";

			///<summary>
			/// 注册时间
			///</summary>
			public const String c_LastTime = "c_LastTime";

			///<summary>
			/// 注册IP
			///</summary>
			public const String c_LastIP = "c_LastIP";

			///<summary>
			/// 状态(0:待审核,1:已审核,2:已锁定)
			///</summary>
			public const String c_State = "c_State";

			///<summary>
			/// 
			///</summary>
			public const String U_Email = "U_Email";

			///<summary>
			/// MSN
			///</summary>
			public const String U_MSN = "U_MSN";

			///<summary>
			/// QQ
			///</summary>
			public const String U_QQ = "U_QQ";

			///<summary>
			/// 移动电话
			///</summary>
			public const String U_MobilePhone = "U_MobilePhone";

			///<summary>
			/// 电话
			///</summary>
			public const String U_Phone = "U_Phone";

			///<summary>
			/// 传真
			///</summary>
			public const String U_Fax = "U_Fax";

			///<summary>
			/// 职位
			///</summary>
			public const String U_Position = "U_Position";
		}
		#endregion
	}
}